const target = process.argv[2]; // v2/v2.7/v3
const { switchVersion } = require("./utils");

if (target === "v2.7") {
  switchVersion(2.7);
  console.log(`[weightbill-designer] Switched for Vue 2.7`);
} else if (target === "v2") {
  switchVersion(2);
  console.log(`[weightbill-designer] Switched for Vue 2`);
} else if (target === "v3") {
  switchVersion(3);
  console.log(`[weightbill-designer] Switched for Vue 3`);
} else {
  console.warn(
    `[weightbill-designer] expecting version "2" or "2.7" or "3" but got "${version}"`
  );
  process.exit(1);
}
